package de.tum.in.eist.poll.client.controllers;

import com.google.gwt.user.client.rpc.AsyncCallback;

import de.tum.in.eist.poll.pub.shared.User;

/**
 * 
 * @author Sebastian Hofstetter
 *
 */
public class LoginController extends Controller {
	
	public void login(String name, String password, AsyncCallback<User> callback) throws IllegalArgumentException {
		pollService.login(name, password, callback);
	}

	/**
	 * 
	 */
	public void logout() {
		Controller.controller.loggedInUser = null;
		Controller.controller.showCurrentPage();
	}
}
